package zy;

import java.util.Scanner;

public class Test {
    public static void main(String[] args) {
        Scanner in =new Scanner(System.in);
        Gongshi g =new Gongshi();
        g.dz="合肥";
        g.mc="小螺号";
        g.fw="洗脚";
        g.hm="12345667";
        int choice=0;
        while (true){
            System.out.println("1,添加员工，2，输出员工信息，3辞退员工，4涨工资，5查找最高工资的员工，6退出");
            choice=in.nextInt();
            if (choice==1){
                Yuangong yu =new Yuangong();
                System.out.println("请输入姓名");
                yu.name=in.next();
                System.out.println("请输入工号");
                yu.gonghao= in.nextInt();
                System.out.println("请输入性别");
                yu.sex = in.next();
                System.out.println("职务");
                yu.zhiwu =in.next();
                System.out.println("薪水");
                yu.xinshui = in.nextInt();
                System.out.println("身份证号");
                yu.sfzh =in.next();
                System.out.println("工作年限");
                yu. gznx = in.nextInt();
                g.add(yu);

            }else if (choice==2){
                g.show();
            }else if (choice==3){
                System.out.println("输入辞退员工姓名");
                String name=in.next();
                g.fire(name);
            }else if (choice==4){
                System.out.println("输入员工姓名");
                String name = in.next();
                g.addMoney(name);
            }else if (choice==5){
                g.maxMoney();
            }
            else if (choice==6){
                break;
            }
        }
        System.out.println("退出了");
    }
}
